Skip to content

feat: create and enforce blocked file extension list for custom outputs#377

Open
ssrhaso wants to merge 2 commits intomainfrom
feat/blocked-filetypes-124
Open

feat: create and enforce blocked file extension list for custom outputs#377
ssrhaso wants to merge 2 commits intomainfrom
feat/blocked-filetypes-124

Conversation

@ssrhaso
Copy link
Copy Markdown
Contributor

@ssrhaso ssrhaso commented Apr 9, 2026

Summary

  • Add a configurable blocked_extensions list in default.yaml (.svg, .gph) to prevent potentially disclosive file types from being added as custom outputs or plots
  • Centralize file extension validation in Records.add_custom() - replaces the hardcoded .gph check in the Stata parser
  • Apply the same extension check to hist(), pie(), and survival_plot() outputs

Closes #124

@jim-smith

@ssrhaso ssrhaso self-assigned this Apr 9, 2026
@ssrhaso ssrhaso requested a review from jim-smith April 9, 2026 12:00
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 9, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.70%. Comparing base (fe1f204) to head (5c2dc10).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #377   +/-   ##
=======================================
  Coverage   99.70%   99.70%           
=======================================
  Files           9        9           
  Lines        1354     1373   +19     
=======================================
+ Hits         1350     1369   +19     
  Misses          4        4           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ssrhaso ssrhaso requested a review from JessUWE April 9, 2026 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]Create and enforce whitelist/blacklist of allowed filetypes in custom output

1 participant